﻿using System;
using System.Globalization;
using System.Windows;
using System.Windows.Data;
using DCT.ViewModel;

namespace DCT.View
{
    [ValueConversion(typeof(EditModeState), typeof(bool))]
    public class EditModeToIsDropTargetConverter : IValueConverter
    {
        public object Convert(object value, Type typeTarget, object param, CultureInfo culture)
        {
            if (typeTarget == typeof(bool))
            {
                return (EditModeState)value == EditModeState.Insert ? true : false;
            }

            return null;
        }
        public object ConvertBack(object value, Type typeTarget, object param, CultureInfo culture)
        {
            return null;
        }
    }
}
